Geometry of binary search trees